<template>
  <div class="contanier border_top">
    <div class="nav flex align-center">
      <div
        v-for="(item, index) in navList"
        :key="index"
        class="flex align-center"
        :class="nav_act == index ? 'active' : ''"
        v-on:mousemove="navhover(index)"
      >{{ item.text }}</div>
    </div>
    <ul class="m-0 p-0 xglj flex justify-between mt-2">
      <li style="margin-left:28px;" v-for="(n,m) in xgljList" :key="m">{{n.linkurl}}</li>
    </ul>
  </div>
</template>

<script>
export default {
  name: "indexhead",
  data() {
    return {
      navList: [
        {
          path: "/",
          text: "相关链接",
        },
      ],
      nav_act: 0,
      currentPage: "1",
      pageSize: "10",
      state: "3",
      xgljList: [],
    };
  },
  methods: {
    navclcik(index, path) {
      this.nav_act = index;
    },
    getlbt() {
      this.$api
        .getljlbt({
            currentPage: this.currentPage,
            pageSize: this.pageSize,
            state: this.state,
          }
        )
        .then((res) => {
          this.xgljList = res.data.data.list;
        })
        .catch(() => {});
    },
  },
};
</script>

<style lang="stylus" scoped>
.contanier {
  width: 1200px;
  height: 96px;
  background: #FFFFFF;
  margin-top: 25px;
  margin-bottom: 25px;
  box-shadow: 0px 0px 10px 0px rgba(0, 0, 0, 0.1);
}

.nav {
  position: relative;
}

.nav>div {
  height: 40px;
  font-size: 16px;
  font-weight: 400;
  color: #BF242A;
  padding: 0 20px;
  cursor: pointer;
}

.nav>div.active {
  color: #ffffff;
  border-color: #ffffff;
  background: #EB424C;
  // border-image: -webkit-linear-gradient(to right, #00036B, #409EFF) 30 30;
  // border-image: -moz-linear-gradient(to right, #00036B, #409EFF) 30 30;
  // border-image: linear-gradient(to right, #00036B, #409EFF) 30 30;
}

.xglj {
  li {
    list-style: none;
    color: #323131;
    font-size: 14px;
  }
}
</style>
